 /**
  * @description 成功或失败的响应模型
  * 成功
  * @author 盘挂他爹
  */

 class ResponseModel {

     success(data: Object = {}, msg: string = "成功") {
            return {
                success: true,
                msg,
                data: {...data}
            }
     }

     error(errorInfo: Object = {}) {
         return {
             success: false,
             data:"",
             ...errorInfo
         }
     }
 }

 export default new ResponseModel()